home *** CD-ROM | disk | FTP | other *** search
/ MacWorld 2003 May (DVD) / Macworld Resource DVD May 2003.toast / Data / Software / Bonus / Database / mysql-max-3.23.55.sit / mysql-max-3.23.55-apple-darwi.1 / mysql-test / t / varbinary.test < prev    next >
Encoding:
Text File  |  2003-01-21  |  478 b   |  17 lines  |  [TEXT/ttxt]

  1. #
  2. # varbinary as string and number
  3. #
  4.  
  5. select 0x41,0x41+0,0x41 | 0x7fffffffffffffff | 0,0xffffffffffffffff | 0 ;
  6. select 0x31+1,concat(0x31)+1,-0xf;
  7.  
  8. #
  9. # Test of hex constants in WHERE:
  10. #
  11.  
  12. create table t1 (ID int(8) unsigned zerofill not null auto_increment,UNIQ bigint(21) unsigned zerofill not null,primary key (ID),unique (UNIQ) );
  13. insert into t1 set UNIQ=0x38afba1d73e6a18a;
  14. insert into t1 set UNIQ=123; 
  15. explain select * from t1 where UNIQ=0x38afba1d73e6a18a;
  16. drop table t1;
  17.